package com.quectel.cms.vo.scheduling;

import com.fasterxml.jackson.annotation.JsonFormat;
import io.swagger.v3.oas.annotations.media.Schema;
import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;

import java.io.Serializable;
import java.util.Date;
import java.util.List;

/**
 * 考勤组管理 排班设置，处理后返回页面的数据
 *
 * @author: bob
 * @email: bob.yu@quectel.com
 * @date: 2023-07-19 13:15:00
 */
@Data
@Schema
public class SchedulingAttendanceGroupPersonWorkTimeResp {

    @Schema(description = "人员id")
    private Long id;

    @Schema(description = "人员名称")
    private String name;

    @Schema(description = "日期和时间配置的数组")
    private List<DateWorkTimeConfig> gtArray;



    /************ 内部类 start ************/
    @Data
    @Schema
    @AllArgsConstructor
    @NoArgsConstructor
    public static class DateWorkTimeConfig implements Serializable {

        @Schema(description = "日期")
        @JsonFormat(pattern = "yyyy-MM-dd", timezone = "GMT+8")
        private Date date;

        @Schema(description = "时间配置信息")
        private List<ExecInfo> execInfos;
    }

    @Data
    @Schema
    @AllArgsConstructor
    @NoArgsConstructor
    public static class ExecInfo implements Serializable {

        @Schema(description = "时间段名称")
        private Long timeConfigId;

        @Schema(description = "时间段名称")
        private String name;

        @Schema(description = "上班时间")
        private String workTime;

        @Schema(description = "下班时间")
        private String closingTime;

    }
    /************ 内部类 end ************/

}
